using System;
using System.Data;
using System.Configuration;
using System.Collections.Generic;
using System.Data.SQLite;
using Common;

namespace BusDiary.Access
{
    public partial class DiaryContent
    {
        /// <summary>
        /// 获得今天的日志内容
        /// </summary>
        /// <returns></returns>
        public BusDiary.Entity.DiaryContent GetTodayDiaryContent()
        {
            SQLiteParameter[] parameters = new SQLiteParameter[]{
                new SQLiteParameter("@Date", DateTime.Now.Date)};

            string sql = selectSQL + " where Date=@Date";

            IDataReader reader = SQLiteHelper.ExecuteReader(sql, parameters);

            return GetSingle(reader);
        }
    }
}

